<%@ page language="java" pageEncoding="UTF-8"%>
<div ng-controller="SoftwareEditController">
	<form role="form" callback="save" validate>
		<div class="form-group">
			<label>
				软件名称
			</label>
			<input type="text" class="form-control" placeholder="请输入名称" name="name" ng-model="software.name" rule="required;">
		</div>
		<div class="form-group">
			<label>
				软件标题
			</label>
			<input type="text" class="form-control" placeholder="请输入名称" name="title" ng-model="software.title" rule="required;">
		</div>
		<div class="form-group">
			<label>
				软件图标
			</label>
			<div class="input-group">
				<input type="text" class="form-control" placeholder="请输入名称" name="icon" ng-model="software.icon" rule="required;">
				<span class="input-group-btn">
					<button type="button" class="btn btn-default" callback="changeIcon" path="/upload/software/icon" message="上传图标" tooltip upload>
						<i class="glyphicon glyphicon-upload"/>
					</button>
				</span>
			</div>
		</div>
		<div class="form-group">
			<label>
				软件主页
			</label>
			<input type="text" class="form-control" name="home_page" ng-model="software.home_page">
		</div>
		<div class="form-group">
			<label>
				文档地址
			</label>
			<input type="text" class="form-control" name="doc_url" ng-model="software.doc_url">
		</div>
		<div class="form-group">
			<label>
				下载地址
			</label>
			<input type="text" class="form-control" name="download_url" ng-model="software.download_url">
		</div>
		<div class="form-group">
			<label>
				软件介绍
			</label>
			<textarea name="introduce" rule="required;" ng-model="software.introduce" editor-width="100%;" editor></textarea>
		</div>
		<div>
			<button type="submit" class="btn btn-success btn-sm"><i class="glyphicon glyphicon-ok"/> 保存</button>
			<button type="button" class="btn btn-danger btn-sm" ng-click="cancel()"><i class="glyphicon glyphicon-remove"/> 取消</button>
		</div>
	</form>
</div>